﻿using FreeSql.DatabaseModel;using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using System.Threading.Tasks;
using Newtonsoft.Json;
using FreeSql.DataAnnotations;

namespace Simple.Repository.SimpleEntitys {

	/// <summary>
	/// 员工登录日志
	/// </summary>
	[JsonObject(MemberSerialization.OptIn), Table(Name = "employee_login_logs", DisableSyncStructure = true)]
	public partial class EmployeeLoginLogs {

		/// <summary>
		/// 主键Id
		/// </summary>
		[JsonProperty, Column(Name = "id", DbType = "bigint", IsPrimary = true, IsIdentity = true)]
		public long Id { get; set; }

		/// <summary>
		/// 公司Id
		/// </summary>
		[JsonProperty, Column(Name = "company_id", DbType = "bigint")]
		public long CompanyId { get; set; }

		/// <summary>
		/// 员工Id
		/// </summary>
		[JsonProperty, Column(Name = "employee_id", DbType = "bigint")]
		public long EmployeeId { get; set; }

		/// <summary>
		/// 员工登录时间
		/// </summary>
		[JsonProperty, Column(Name = "employee_login_time", DbType = "datetime")]
		public DateTime EmployeeLoginTime { get; set; }

		/// <summary>
		/// 员工登录凭证
		/// </summary>
		[JsonProperty, Column(Name = "employee_token", IsNullable = false)]
		public string EmployeeToken { get; set; }

		/// <summary>
		/// 员工登录凭证失效时间
		/// </summary>
		[JsonProperty, Column(Name = "employee_token_expired_time", DbType = "datetime")]
		public DateTime EmployeeTokenExpiredTime { get; set; }

		/// <summary>
		/// 员工登录凭证是否登出：0=未退出登录、1=主动退出登录、2=强制推出登录（员工删除、禁用、角色变更、角色权限变更、系统版本变更）
		/// </summary>
		[JsonProperty, Column(Name = "is_logout", DbType = "int")]
		public int IsLogout { get; set; }

	}

}
